import request from '@/utils/request'

export function login(data) {
  return request({
    url: '/login/login',
    method: 'post',
    data: data
  })
}

/*
 *重置密码
 * code:验证码
	account:手机号或者邮箱
	password:密码
	type 方式：mobile手机找回 email邮箱找回
 */
export function resetPassword(data) {
  return request({
    url: '/user/resetPassword',
    method: 'post',
    data: data
  })
}

/*
 *获取手机验证码
 * mobile:手机号
 */
export function sendMobileCode(mobile) {
  return request({
    url: '/sendMobileCode	',
    method: 'post',
    data: {
    	mobile
    }
  })
}

/*
  * 获取邮箱验证码
  * email:邮箱
  */
 export function sendEmailCode(email) {
  return request({
    url: '/sendEmailCode',
    method: 'post',
    data: {
    	email
    }
  })
}